package com.xiaohe66.web.infrastructure.mybatis.im.mapper;

import com.xiaohe66.common.value.Paging;
import com.xiaohe66.web.infrastructure.mybatis.im.model.MessageDo;
import com.xiaohe66.web.infrastructure.mybatis.im.model.MessageUnreadDo;
import com.xiaohe66.web.integration.MapperSupport;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author xiaohe
 * @since 2023-08-09 16:00
 */
public interface MessageMapper extends MapperSupport<MessageDo> {

    List<MessageUnreadDo> countByAccountIdUnread(@Param("accountId") Long accountId);

    List<MessageDo> pageOfAccountId(@Param("paging") Paging paging,
                                    @Param("createId") Long createId,
                                    @Param("accountId") Long accountId);

}
